<div id="all">
		<div id="logoarea"></div>
		<div id="header">
			<h1>Bone Banger Online Shop</h1>
			<p>Bone Banger is the online shopping platform for young creative developers of horror and splatter movies. Here you will find everything from bones over intrails to blood.</p>
		</div>
		<div id="loginarea">
			<%if @loggedIn == false%>
				<% form_for :admin, @admin, :url => { :controller => "store", :action => "login" }, :html => { :method => :post} do |f| %>
					<%= f.text_field :uname %>
					<%= f.password_field :pw %>
					<%= f.submit 'Login'%>
					<a href="../store/register">Registrieren</a>
				<% end %>
			<%else%> 
				<p style="color: green"><%= flash[:notice] %></p>
				<p>Hallo <%= session[:user_name] %>,
				<%=link_to 'Logout', url_for(:controller=>'store', :action=>'logout')%>	
				</p>
			<% end %>
		</div>
	<div id="content">
		<div class="float" id="category"><h2>Categories</h2>
			<% @categories.each do |category| %>
				<li class="categoryListItem">
					<%=link_to category.name, url_for(:controller=>'store', 
					:action=>'index', :paramCat => category.id)%><br />
					<span><%=h category.description %></span>
				</li>
			<% end %>
		</div>
		<div id="main">
		<% if @Cat == nil %>
				<h2>What are you looking for?</h2>
				<form action="">
					<input type="textfield" size="60"></input>
				</form>
				<div id="item-gallery">
					<ul class="float">
						<% @products.each do |product| %>
							<%if product.id-1 % 3 == 0%>
								</ul>
								<ul class="float">
							<% end %>
							<li>
								<h2><%=h product.name %></h2>
								<p><%=h product.category.name unless product.category.nil?  %></p>
								<img src="" alt="Item Image" />
								<p><%=h product.description %></p>
								<p><%= number_to_currency(product.price, :unit => "&euro;") %></p>
							</li>
						<% end %>
					</ul>
				</div>
		<% else %>	
			<h2><%= @Cat.name %></h2>
				<p><%=@Cat.description %></p>
				<div id="item-gallery">
					<% if @products != nil %>
						<ul class="float">
							<% @products.each do |product| %>
								<%if product.id-1 % 3 == 0%>
									</ul>
									<ul class="float">
								<% end %>
								<li>
									<h2><%=h product.name %></h2>
									<p><%=h product.category.name unless product.category.nil?  %></p>
									<img src="" alt="Item Image" />
									<p><%=h product.description %></p>
									<p><%= number_to_currency(product.price, :unit => "&euro;") %></p>
								</li>
							<% end %>
						</ul>
					<% end %>
				</div>
		<% end %>
		</div>
		<div id="shopping-cart">
			<h2>Drag a product on me to add it to your shopping cart</h2>
			<div id="cart-listing">
				<ul>
					<li>Item 1</li>
					<li>Item 2</li>
					<li>Item 3</li>
				</ul>
				<ul>
					<li>Amount</li>
					<li>Amount</li>
					<li>Amount</li>
				</ul>
			</div>
		</div>
	</div>
</div>